# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Willow Barraco <contact@willowbarraco.fr>
pkgname=kakoune
pkgver=2023.08.05
pkgrel=0
pkgdesc="Code editor heavily inspired by Vim, but with less keystrokes"
url="https://kakoune.org"
arch="all"
license="Unlicense"
makedepends="asciidoc"
subpackages="$pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/mawww/kakoune/archive/v$pkgver.tar.gz
	alpine-linux.kak
	0001-fix-CXXFLAGS.patch
	constexpr.patch
	"

build() {
	make debug=no
}

check() {
	make check
}

package() {
	make PREFIX="/usr" DESTDIR="$pkgdir/" debug=no install
	install -Dm644 $srcdir/alpine-linux.kak $pkgdir/usr/share/kak/autoload/filetype/
}

sha512sums="
2a7cd029ccebad9be9c8ba3bbde47528e7c98bffd2bdb24456641226ae9977381aff58176d2e2e961e8205a17a4708cde8cf1829c573b0e1a8288eb9748e4c0d  kakoune-2023.08.05.tar.gz
c5b11dc28adf785b4e83637fe1d5c9db334616d2d3f6c667823745e273f739c57d0d408b9bec8a65210e3c7ccb80a5b488ebbb3c0c5de8bdec13e1b4b4d02b77  alpine-linux.kak
23d05861de3c23c8193b1b6d7ca0d2b5b33548c0ae9a317186ccca6533b51daffb9064d3ab9e7ac0a0a794e119633089ca34673b6d9dd56041e2f9046b38b87b  0001-fix-CXXFLAGS.patch
aa5df7a115e7b7ecaba85794ea56961fd1c638f4590300474fa72c8900ecb36742d7c8075ebc48151f40ba2dc427c4d8bcca9c844793768a1d0c4e66f22d328c  constexpr.patch
"
